<div class="content">
	<div class="content_header_left">
		<!-- Start Content Header Left -->
		<?php include("ws_includes/1_ws_inc_priviligestring.php"); ?>
		<?php include("ws_includes/2_ws_inc_headerlabel.php"); ?>
		<?php include("ws_includes/3_ws_inc_errorlabel.php"); ?>
		<!-- End Content Header Left -->
	</div>
	<div class="content_header_right">
		<!-- Start Content Header Right -->
		<a title="Add" href="action/act_modules_addedit.php" class="nyroModal">
			<img class="lazy" src="<?php echo getURLdomain(); ?>/source/global/img/grey.gif" data-original="<?php echo getURLdomain(); ?>/source/global/img/add-icon.png" width="24" />
			<noscript><img src="<?php echo getURLdomain(); ?>/source/global/img/add-icon.png" width="24"></noscript>
		</a>
		<!-- End Content Header Right -->
	</div>
	<div style="clear:both;"></div>
	<div class="content_body">
		<!-- Start Content Body -->
		<?php
			$sql_sub = "select modulesub2urltype, modulesub2id from ms_module_sub_2 where stsrc = 'A' and modulesub2urltype <> 'management' order by modulesub2urltype asc, modulesub2position asc";
			$exe_sub = mysql_query($sql_sub) or die(mysql_error());
			$num_sub = mysql_num_rows($exe_sub);
			
			if($num_sub > 0)
			{
		?>
		<table id="table" border="1" cellpadding="2" cellspacing="0">
		<thead>
			<tr>
				<th>Sub Module 2 ID</th>
				<th>Sub Module 2 Type</th>
				<th>Parent Sub Module Name</th>
				<th>Sub Module 2 Name</th>
				<th>Sub Module 2 Label</th>
				<th>Sub Module 2 Front URL</th>
				<th>Sub Module 2 Back URL</th>
				<th filter="false">Action</th>
			</tr>
		</thead>
		<?php
				while($row_sub = mysql_fetch_array($exe_sub))
				{
					$sql_dtl = "select b.modulesubname as modulesubname,a.* from ms_module_sub b left join ms_module_sub_2 a on a.modulesubid = b.modulesubid where a.modulesub2id = '".$row_sub['modulesub2id']."' ";
					$exe_dtl = mysql_query($sql_dtl) or die(mysql_error());
					$row = mysql_fetch_array($exe_dtl);
					
					
		?>
			<tr>
				<td><?php echo $row['modulesub2id']; ?></td>
				<td><?php echo $row['modulesub2urltype']; ?></td>
				<td><?php echo $row['modulesubname']; ?></td>
				<td><?php echo $row['modulesub2name']; ?></td>
				<td><?php echo $row['modulesub2label']; ?></td>
				<td><?php echo $row['modulesub2urlfront']; ?></td>
				<td><?php echo $row['modulesub2urlback']; ?></td>
				<td>
					<div style="width:100%;">
						<div class="divRowActionCell">
							<div class="divRowAction">
								<a title="Preview" href="action/act_modules_preview.php#<?php echo $row['moduleid']; ?>" class="nyroModal">
									<img class="lazy" src="<?php echo getURLdomain(); ?>/source/global/img/grey.gif" data-original="<?php echo getURLdomain(); ?>/source/global/img/preview-icon.png" width="24" />
									<noscript><img src="<?php echo getURLdomain(); ?>/source/global/img/preview-icon.png" width="24"></noscript>
								</a>
							</div>
							<div class="divRowAction">
								<a title="Edit" href="action/act_modules_addedit.php#<?php echo $row['moduleid']; ?>" class="nyroModal">
									<img class="lazy" src="<?php echo getURLdomain(); ?>/source/global/img/grey.gif" data-original="<?php echo getURLdomain(); ?>/source/global/img/edit-icon.png" width="24" />
									<noscript><img src="<?php echo getURLdomain(); ?>/source/global/img/edit-icon.png" width="24"></noscript>
								</a>
							</div>
							<div class="divRowAction">
								<a title="Delete" href="action/act_modules_delete.php#<?php echo $row['moduleid']; ?>" class="nyroModal">
									<img class="lazy" src="<?php echo getURLdomain(); ?>/source/global/img/grey.gif" data-original="<?php echo getURLdomain(); ?>/source/global/img/delete-icon.png" width="24" />
									<noscript><img src="<?php echo getURLdomain(); ?>/source/global/img/delete-icon.png" width="24"></noscript>
								</a>
							</div>
							<div class="clear"></div>
						</div>
					</div>
				</td>
			</tr>
		<?php
				}
			}
			else
			{
		?>
				No data !
		<?php
			}
		?>
		</table>
		<!-- End Content Body -->
	</div>
	<div style="clear:both;"></div>
</div>
